<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>登录</title>
    <style>
        *{
            margin:0;
            padding:0;
            box-sizing:border-box;
        }
        body {
            background-image: url("img/bg.jpg");
            background-size: cover;
            font-family: "微软雅黑", sans-serif;
        }
        .login {
            position: absolute;
            top: 50%;
            left: 50%;
            margin: -150px 0 0 -150px;
            width:300px;
            height:300px;
        }
        .login h1 {
            color:#555555;
            text-shadow: 0px 10px 10px #CDC673;
            letter-spacing:2px;text-align:center;
            margin-bottom:20px;
        }
        input{
            padding:10px;
            width:100%;
            color:white;
            margin-bottom:10px;
            background-color:#555555;
            border: 1px solid black;
            border-radius:5px;
            letter-spacing:2px;
        }
        form button{
            width:100%;
            padding:10px;
            margin-bottom:10px;
            background-color:#CDC673;
            border:1px solid black;
            border-radius:5px;
            cursor:pointer;
        }
    </style>
</head>
<body class="login">
    <h1>Login</h1>
    <form action="" method="post" id="loginForm">
        <input id="username" type="text" name="username" placeholder="请求输入用户名">
        <span id="usernameMsg" style="color: red;display: none">用户名不符合规则</span>
        <input id="password" type="password" name="password" placeholder="请输入密码">
        <span id="passwordMsg" style="color: red;display: none">密码不符合规则</span>
        <button type="submit" id="login">登录</button>
        <button type="submit">注册</button>
    </form>

    <script>
		//在此处编写js代码实现功能

    </script>
</body>
</html>